import React from 'react'
import {HashRouter, Route, Switch, Redirect} from 'react-router-dom'
import asyncComponent from '@/utils/asyncComponent'
const Index = asyncComponent(() => import("@/pages/index/index"))
const Exchange = asyncComponent(() => import("@/pages/exchange/exchange"))

const BasicRoute = () => (
    <HashRouter>
        <Switch>
            <Route exact path="/index" component={Index}/>
            <Route exact path="/exchange" component={Exchange}/>
            <Redirect exact from='/' to='/index'/>
        </Switch>
    </HashRouter>
);


export default BasicRoute;